
R3F_FNCT_Kamikaze = {
	private ["_side","_param","_kamikaze","_units","_distance","_ammo","_trust","_trigger","_destroy","_pos","_explo"];
	_side = _this select 0;
	if (typeName _side != "SIDE") exitWith {};
	_param = _this select 1;
	if (isNil "_param") exitWith {};
	if (typeName _param == "OBJECT") then {
		_kamikaze = _param;
	} else {
		if (typeName _param == "GROUP") then {
			_units = units _param;
			_kamikaze = _units select (floor (random (count _units)));
		};
	};
	if (typeName _kamikaze != "OBJECT") exitWith {};
	_distance = if (count _this > 2) then {_this select 2;} else {15;};
	if (typeName _distance != "SCALAR") exitWith {};
	_ammo = if (count _this > 3) then {_this select 3;} else {"Sh_105_HE";};
	if (typeName _ammo != "STRING") exitWith {};
	_trust = if (count _this > 4) then {_this select 4;} else {1;};
	if (typeName _trust != "SCALAR") exitWith {};
	_kamikaze allowFleeing 0;
	_kamikaze setskill ["courage",1];
	_kamikaze setskill ["spotDistance",0];
	_kamikaze setskill ["spotTime",0];
	_kamikaze disableAI "AUTOTARGET";
	_kamikaze disableAI "TARGET";
	_trigger = false;
	_destroy = false;
	while {!_trigger && !(isNull _kamikaze)} do {
		_pos = position _kamikaze;
		_units = nearestObjects [_pos,["Man","Car","Tank","Motorcycle"],_distance];
		if (count _units > 0) then {
			{	if ((side _x == _side) && alive _x) exitWith {_trigger = true;};
				sleep 0.01;
			} forEach _units;
		};
		if ((damage (vehicle _kamikaze) > 0.7) || !(alive _kamikaze)) then {_trigger = true;_destroy = true;};
		if (_trigger) then {
			if (((random 1 <= _trust) && (_trust > 0)) || _destroy) then {
				_distance = (speed _kamikaze) / 1.5; 
				_pos = [_kamikaze,_distance,direction _kamikaze] call BIS_fnc_relPos;
				[_ammo,_pos] spawn R3F_FNCT_Explo;
				if (vehicle _kamikaze != _kamikaze) then {(vehicle _kamikaze) setDamage 1; [_ammo,_pos] spawn R3F_FNCT_Explo;};
				_kamikaze setDamage 1;
				if (!isNil "ACV_FNCT_Broadcast_BIS_Effects_Burn") then {[_pos,5,40] spawn ACV_FNCT_Broadcast_BIS_Effects_Burn;};
			} else {
				["SmokeShell",_pos,0,3] call R3F_FNCT_Fumi;
			};
		};
		sleep 1;
	};
};
